const http = require('http')
const fs = require('fs')
http.createServer((req, res) => {
    let urlString = req.url;
    switch (urlString) {
        case '/':
            res.end('hello')
            break;
        case '/home':
            fs.readFile('./home.html', (err, content) => {
                res.end(content)
            })
            break;
        case '/ak.js':
            fs.readFile('./ak.js', (err, content) => {
                res.end(content)
            })
            break;
        default:
            res.end('404')
    }

}).listen(3000, () => {
    console.log(0000);
})